﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using DAL;
using System.Data;
using Model;

namespace BLL
{
    public class CardUserBO
    {
        public CardUserBO() { }

        CardUserDAO dao = new CardUserDAO();

        /// <summary>
        /// 增加一条数据
        /// </summary>
        public int Add(CardUser model)
        {
            return dao.Add(model);
        }
        /// <summary>
        /// 更新一条数据
        /// </summary>
        public int Update(CardUser model)
        {
            return dao.Update(model);
        }

        /// <summary>
        /// 删除一条数据
        /// </summary>
        public void Delete(int id)
        {
             dao.Delete(id);
        }


        /// <summary>
        /// 得到一个对象实体
        /// </summary>
        public CardUser GetModel(string FromUserName)
        {
            return dao.GetModel(FromUserName);
        }

        /// <summary>
        /// 获得数据列表
        /// </summary>
        public DataSet GetList(string strWhere)
        {
            return dao.GetList(strWhere);
        }

        /// <summary>
        /// 获得前几行数据
        /// </summary>
        public DataSet GetList(int Top, string strWhere, string filedOrder)
        {
            return dao.GetList(Top, strWhere, filedOrder);
        }
    }
}
